﻿using System;
using System.IO;
using System.Linq;
using Calais;

namespace Calais.RDFSProcess
{
    class Program
    {
        static void Main(string[] args)
        {
            var eBuilder = new CalaisEnumBuilder();
            eBuilder.Process();

            TextWriter twe = new StreamWriter(@"..\..\Enums\CalaisGeneratedEnums.cs");
            twe.WriteLine("namespace Calais");
            twe.WriteLine("{");
            twe.WriteLine(eBuilder.GenerateAllEnums());
            twe.WriteLine("}");
            twe.Close();
            Console.WriteLine("Enums - \t[DONE]");

            var builder = new CalaisInterfaceBuilder();
            builder.Process();

            TextWriter tw = new StreamWriter(@"..\..\Interfaces\CalaisGeneratedInterfaces.cs");
            tw.WriteLine("namespace Calais");
            tw.WriteLine("{");
            tw.WriteLine(builder.GenerateAllInterfaces());
            tw.WriteLine("}");
            tw.Close();
            Console.WriteLine("Interfaces - \t[DONE]");

            TextWriter twc = new StreamWriter(@"..\..\Classes\CalaisGeneratedClasses.cs");
            twc.WriteLine("namespace Calais");
            twc.WriteLine("{");
            twc.WriteLine(builder.GenerateAllClasses());
            twc.WriteLine("}");
            twc.Close();

            Console.WriteLine("Classes - \t[DONE] \nPress any key to continue ...");

            Console.ReadKey();
        }
    }
}
